// GeomView.h : interface of the CGeomView class
//


#pragma once
class CGeomDoc;
class CAnyView;
class CEditorMgr;

class GEOMUIAPI CGeomView : public CView
{
protected: // create from serialization only
	CGeomView();
	DECLARE_DYNCREATE(CGeomView)

	CAnyView* m_pDrawView;
	CEditorMgr* m_pEditorMgr;
// Attributes
public:
	CGeomDoc* GetDocument() const;
// Operations
protected:
	void ShowEditorProp();
// Overrides
public:
	virtual void OnDraw(CDC* pDC);  // overridden to draw this view
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);

protected:
	virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
	virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);

// Implementation
public:
	virtual ~CGeomView();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:

// Generated message map functions
protected:
	afx_msg void OnFilePrintPreview();
	DECLARE_MESSAGE_MAP()
public:
	virtual void OnInitialUpdate();
	afx_msg void OnSize(UINT nType, int cx, int cy);


	afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
	afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnMouseMove(UINT nFlags, CPoint point);
	afx_msg BOOL OnMouseWheel(UINT nFlags, short zDelta, CPoint pt);
	afx_msg void OnRButtonUp(UINT nFlags, CPoint point);
	afx_msg void OnRButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);
	afx_msg void OnChar(UINT nChar, UINT nRepCnt, UINT nFlags);
	afx_msg void OnKeyUp(UINT nChar, UINT nRepCnt, UINT nFlags);

	afx_msg void OnContextMenu(CWnd* /*pWnd*/, CPoint /*point*/);
	afx_msg LRESULT OnStartEditor(WPARAM wp, LPARAM lp);
	afx_msg LRESULT OnReceiveCommand(WPARAM wp, LPARAM lp);
	afx_msg LRESULT OnPropAction(WPARAM wp, LPARAM lp);
	afx_msg LRESULT OnSketchPlaneMessage(WPARAM wp, LPARAM lp);
protected:
	virtual void OnActivateView(BOOL bActivate, CView* pActivateView, CView* pDeactiveView);
};

#ifndef _DEBUG  // debug version in GeomView.cpp
inline CGeomDoc* CGeomView::GetDocument() const
   { return reinterpret_cast<CGeomDoc*>(m_pDocument); }
#endif

